//
//  BMSAPIService.h
//  BMSSDK
//
//  Created by YeJary on 2025/4/27.
//

#import <Foundation/Foundation.h>

NS_ASSUME_NONNULL_BEGIN

@interface BMSAPIService : NSObject

/// 获取游戏启动配置参数
/// - Parameters:
///   - version: version
///   - appName: appName
///   - success: 成功回调
///   - failure: 失败回调
+ (void)fetchGameLaunchConfigWithVersion:(NSString *)version
                                 appName:(NSString *)appName
                                 success:(void(^)(id responseObject))success
                                 failure:(void(^)(NSError *error))failure;


/// 获取国家法定节假日列表
/// - Parameters:
///   - success: 成功回调
///   - failure: 失败回调
+ (void)fetchOfficialHolidaysWithSuccess:(void(^)(id responseObject))success
                                 failure:(void(^)(NSError *error))failure;

/// IP 屏蔽接口
/// - Parameters:
///   - appName: BMS 唯一标识符
///   - channel: 游戏渠道
///   - version: 游戏版本
///   - ip: IP 地址（可不传）
///   - success: 成功回调
///   - failure: 失败回调
+ (void)checkIPBlockStatusWithAppName:(NSString *)appName
                              channel:(NSString *)channel
                              version:(NSString *)version
                                   ip:(nullable NSString *)ip
                              success:(void(^)(NSDictionary *response))success
                              failure:(void(^)(NSError *error))failure;

/// 实名认证
/// - Parameters:
///   - name: 姓名
///   - idCard: 身份证
///   - zxbAppId: 中宣部 appID
///   - success: 成功回调结果
///   - failure: 失败回调结果
+ (void)submitRealnameWithName:(NSString *)name
                        idCard:(NSString *)idCard
                      zxbAppId:(nullable NSString *)zxbAppId
                       success:(void(^)(NSDictionary *response))success
                       failure:(void(^)(NSError *error))failure;

/// 获取用户买量来源
/// - Parameters:
///   - appName: BMS打点唯一标识
///   - version: BMS打点版本号
///   - channel: BMS 打点 channel
///   - uuid: BMS 打点 UUID
///   - idfa: idfa
///   - idfv: idfv
///   - imei: imei
///   - oaid: oaid
///   - android_id: ios 传空
///   - success: 成功回调
///   - failure: 失败回调
+ (void)fetchUserSourceWithAppName:(NSString *)appName
                           version:(NSString *)version
                           channel:(NSString *)channel
                              uuid:(NSString *)uuid
                              idfa:(nullable NSString *)idfa
                              idfv:(nullable NSString *)idfv
                              imei:(nullable NSString *)imei
                              oaid:(nullable NSString *)oaid
                        android_id:(nullable NSString *)android_id
                           success:(void(^)(NSDictionary *response))success
                           failure:(void(^)(NSError *error))failure;

/// SDK 静默登录接口
/// - Parameters:
///   - openid: 客服端用户唯一标识
///   - appName: bms唯一标识
///   - platform: 平台 ，需为android或ios
///   - idfa: idfa
///   - idfv: idfv
///   - imei: imei
///   - oaid: oaid
///   - adid: adid
///   - mac: ios传空
///   - serial: iOS 传空
///   - success: 成功回调
///   - failure: 失败回调
+ (void)loginWithOpenId:(NSString *)openid
                appName:(NSString *)appName
               platform:(NSString *)platform
                   idfa:(nullable NSString *)idfa
                   idfv:(nullable NSString *)idfv
                   imei:(nullable NSString *)imei
                   oaid:(nullable NSString *)oaid
                   adid:(nullable NSString *)adid
                    mac:(nullable NSString *)mac
                 serial:(nullable NSString *)serial
                success:(void(^)(NSDictionary *response))success
                failure:(void(^)(NSError *error))failure;

/// 数据上报
/// - Parameters:
///   - params: 参数
///   - traceId: 唯一标识符
///   - success: 成功回调
///   - failure: 失败回调
+ (void)uploadMergedReportWithParams:(NSDictionary *)params
                             traceId:(NSString *)traceId
                             success:(void(^)(id responseObject))success
                             failure:(void(^)(NSError *error))failure;

@end

NS_ASSUME_NONNULL_END
